package com.newtouch.bxzs.common.base.model;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * 用户课程实体类
 *
 * <p>
 * <b>History:</b>
 * <table border="1">
 * <tr>
 * <th>Date</th>
 * <th>Operator</th>
 * <th>Memo</th>
 * </tr>
 * <tr>
 * <td>2021/2/23 9:36</td>
 * <td>dingqianbin</td>
 * <td>Create</td>
 * </tr>
 * </table>
 *
 * @author dingqianbin
 * @version 1.0.0
 * @since 1.0.0
 */
@Data
@TableName(value = "ASSISTANT_USER_COURSE")
@ApiModel(value = "用户课程实体类")
public class UserCourse implements Serializable {

    private static final long serialVersionUID = 5396819783711063565L;
    
    /** 主键用户课程ID */
    @TableId(value = "USER_COURSE_ID", type = IdType.ASSIGN_UUID)
    private String userCourseId;

    /** 课程ID */
    @TableField(value = "COURSE_ID")
    private String courseId;

    /** 用户课程评分 */
    @TableField(value = "USER_COURSE_SCORE")
    private Integer userCourseScore;

    /** 用户课程学习时长 */
    @TableField(value = "USER_COURSE_LEARNING_DURATION")
    private Double userCourseLearningDuration;

    /** 用户课程时长 */
    @TableField(value = "COURSE_DURATION")
    private Double courseDuration;

    /** 是否设为学习目标:1,是 0,否 */
    @TableField(value = "IS_LEARNING_INSURANCE")
    private Integer isLearningInsurance;

    /** 创建用户ID */
    @TableField(value = "CREATE_USER_ID")
    private String createUserId;

    /** 创建时间 */
    @TableField(value = "CREATE_TIME")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "CST")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /** 修改用户ID */
    @TableField(value = "UPDATE_USER_ID")
    private String updateUserId;

    /** 修改时间 */
    @TableField(value = "UPDATE_TIME")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "CST")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    /** 删除状态 */
    @TableField(value = "IS_DELETE")
    @TableLogic(value = "0", delval = "1")
    private Boolean deleteFlag = false;

    /** 备注 */
    @TableField(value = "MEMO")
    private String memo;
}
